import { mapData } from '@/apis/map'

const state = {
  houseData: []
}
const mutations = {
  updataHouseData (state, payload) {
    state.houseData = payload
  }
}
const actions = {
  async getMapData (ctx, payload) {
    const { data } = await mapData(payload)
    await ctx.commit('updataHouseData', [])
    ctx.commit('updataHouseData', data.body)
  }
}
const getters = {
}
export default {
  namespaced: true,
  state,
  mutations,
  actions,
  getters
}
